package com.cn.action;

import javax.servlet.http.HttpSession;

import org.apache.struts2.ServletActionContext;

import com.cn.dao.OrderXiangmuDao;
import com.cn.entity.Order_xiangmu;
import com.opensymphony.xwork2.Action;

public class Order_xiangmuUpdateAction implements Action{
	
	 Order_xiangmu ox;

	public Order_xiangmu getOx() {
		return ox;
	}

	public void setOx(Order_xiangmu ox) {
		this.ox = ox;
	}

	@Override
	public String execute() throws Exception {
		// TODO Auto-generated method stub
		OrderXiangmuDao od=new OrderXiangmuDao();
		System.out.println(ox.getResult());
		System.out.println(ox.getXiangmuid());
		System.out.println(ox.getOrderid());
		od.update(ox);
		HttpSession session=ServletActionContext.getRequest().getSession();
		session.setAttribute("orderid", ox.getOrderid());
		return "success";
	}
	 

}
